package imsdk

const (
	TIM_MSG_TYPE_TEXT   = "TIMTextElem"   // 文本消息
	TIM_MSG_TYPE_CUSTOM = "TIMCustomElem" // 其他消息JSON 格式（延续老版本的协议）
)
const (
	TIM_CODE_OK           = 0     //允许发言
	TIM_ERROR_CODE_REJECT = 1     //禁止发言
	TIM_ERROR_ERROR       = 10100 //返回错误给客户端
	TIM_ERROR_ERROR_SQL   = 10104 //查数据出错
	TIM_ERROR_RISK_BAN    = 10177 //发言失败
	TIM_ERROR_CODE_IGNORE = 2     //静默丢弃

	// 请将错误码 ErrorCode 设置在 [120001, 130000] 区间内
	TIM_C2C_REJECT = 120001 // 私聊拒绝发言

	// 粉丝群
	TIM_FANSG_REJECT_FAILTIPS = 10121 // 粉丝群发送失败提示
	TIM_FANSG_REJECT_DISOLVE  = 10122 // 粉丝群解散
	TIM_FANSG_REJECT_BAN      = 10123 // 粉丝群禁言
)
const (
	connTimeoutMs  = 5000
	serveTimeoutMs = 10000
)
const (
	FailActionStatus = "FAIL"
	OKActionStatus   = "OK"
)

const (
	PrivateGroup = "Private"
	AvChatGroup  = "AVChatRoom"
)

const (
	TIM_SEND_GIFT_OK   = 10151
	TIM_SEND_GIFT_ERR  = 10152
	TIM_SEND_PROPS_ERR = 10153
)

type SendImResponse struct {
	ActionStatus string `json:"ActionStatus"`
	ErrorInfo    string `json:"ErrorInfo"`
	ErrorCode    int    `json:"ErrorCode"`
}
